package com.web.controller.quartz;

import com.service.CompanyService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.context.support.SpringBeanAutowiringSupport;

public class CargoQuartz {

    @Autowired
    private CompanyService companyService;

    //定时按照工厂统计销售额
    public void countMoneyByFactory() {
        //将autowired交给spring管理
        SpringBeanAutowiringSupport.processInjectionBasedOnCurrentContext(this);
//        //获取统计的数据
        companyService.countMoneyByFactory();
    }
}
